package com.ncsc.lmis.model;
// Generated Feb 25, 2014 11:44:39 PM by Hibernate Tools 3.4.0.CR1


import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import static javax.persistence.GenerationType.IDENTITY;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;
import javax.persistence.UniqueConstraint;

/**
 * SysBranch generated by hbm2java
 */
@Entity
@Table(name="sys_branch"
    ,catalog="lmis"
    , uniqueConstraints = @UniqueConstraint(columnNames="BRANCH_CODE") 
)
public class SysBranch  implements java.io.Serializable {


     private Short branchNo;
     private HrEmp hrEmp;
     private String branchCode;
     private String branchName;
     private String addr1;
     private String addr2;
     private String addr3;
     private Short addr4No;
     private String addr5;
     private String phoneNo;

    public SysBranch() {
    }

	
    public SysBranch(String branchCode) {
        this.branchCode = branchCode;
    }
    public SysBranch(HrEmp hrEmp, String branchCode, String branchName, String addr1, String addr2, String addr3, Short addr4No, String addr5, String phoneNo) {
       this.hrEmp = hrEmp;
       this.branchCode = branchCode;
       this.branchName = branchName;
       this.addr1 = addr1;
       this.addr2 = addr2;
       this.addr3 = addr3;
       this.addr4No = addr4No;
       this.addr5 = addr5;
       this.phoneNo = phoneNo;
    }
   
     @Id @GeneratedValue(strategy=IDENTITY)

    
    @Column(name="BRANCH_NO", unique=true, nullable=false)
    public Short getBranchNo() {
        return this.branchNo;
    }
    
    public void setBranchNo(Short branchNo) {
        this.branchNo = branchNo;
    }

@ManyToOne(fetch=FetchType.LAZY)
    @JoinColumn(name="MGR_NO")
    public HrEmp getHrEmp() {
        return this.hrEmp;
    }
    
    public void setHrEmp(HrEmp hrEmp) {
        this.hrEmp = hrEmp;
    }

    
    @Column(name="BRANCH_CODE", unique=true, nullable=false, length=4)
    public String getBranchCode() {
        return this.branchCode;
    }
    
    public void setBranchCode(String branchCode) {
        this.branchCode = branchCode;
    }

    
    @Column(name="BRANCH_NAME", length=100)
    public String getBranchName() {
        return this.branchName;
    }
    
    public void setBranchName(String branchName) {
        this.branchName = branchName;
    }

    
    @Column(name="ADDR1", length=50)
    public String getAddr1() {
        return this.addr1;
    }
    
    public void setAddr1(String addr1) {
        this.addr1 = addr1;
    }

    
    @Column(name="ADDR2", length=50)
    public String getAddr2() {
        return this.addr2;
    }
    
    public void setAddr2(String addr2) {
        this.addr2 = addr2;
    }

    
    @Column(name="ADDR3", length=50)
    public String getAddr3() {
        return this.addr3;
    }
    
    public void setAddr3(String addr3) {
        this.addr3 = addr3;
    }

    
    @Column(name="ADDR4_NO")
    public Short getAddr4No() {
        return this.addr4No;
    }
    
    public void setAddr4No(Short addr4No) {
        this.addr4No = addr4No;
    }

    
    @Column(name="ADDR5", length=10)
    public String getAddr5() {
        return this.addr5;
    }
    
    public void setAddr5(String addr5) {
        this.addr5 = addr5;
    }

    
    @Column(name="PHONE_NO", length=10)
    public String getPhoneNo() {
        return this.phoneNo;
    }
    
    public void setPhoneNo(String phoneNo) {
        this.phoneNo = phoneNo;
    }




}


